package demo.genericity;

import lombok.Data;
import lombok.extern.slf4j.Slf4j;

/**
 * 泛型
 *
 * @author sun.ye
 * @since 2020-06-29 20:40
 */
@Data
@Slf4j
public class Holder<T> {

    private T myHolder;

    public Holder(T myHolder) {
        this.myHolder = myHolder;
    }

    public void showHolder(){
        log.info(myHolder.toString());
    }

    public static void main(String[] args) {
        new Holder<>("12345").showHolder();
    }
}